home *** CD-ROM | disk | FTP | other *** search
open in:
MacOS 8.1
|
Win98
|
DOS
browse contents |
view JSON data
|
view as text
This file was processed as: Mailbox/MIME Entity
(archive/mbox).
Confidence | Program | Detection | Match Type | Support
|
---|
100%
| dexvert
| Newsgroup Content (archive/news)
| magic
| Supported |
100%
| dexvert
| Mailbox/MIME Entity (archive/mbox)
| magic
| Supported |
100%
| dexvert
| Internet Message Format (text/imf)
| magic
| Supported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| news, ASCII text
| default
| |
100%
| checkBytes
| Printable ASCII
| default
| |
100%
| dexmagic
| PrintFox/Pagefox WEAK
| default
| |
100%
| perlTextCheck
| Likely Text (Perl)
| default
| |
100%
| siegfried
| fmt/950 MIME Email (1.0)
| default
| |
100%
| detectItEasy
| Format: plain text[LF]
| default (weak)
| |
100%
| xdgMime
| message/news
| default
|
|
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 50 61 74 68 3a 20 69 78 | 2e 6e 65 74 63 6f 6d 2e |Path: ix|.netcom.|
|00000010| 63 6f 6d 21 6e 65 74 6e | 65 77 73 0a 46 72 6f 6d |com!netn|ews.From|
|00000020| 3a 20 5a 61 63 68 61 72 | 79 20 43 61 72 74 65 72 |: Zachar|y Carter|
|00000030| 20 3c 7a 63 61 72 74 65 | 72 40 69 78 2e 6e 65 74 | <zcarte|r@ix.net|
|00000040| 63 6f 6d 2e 63 6f 6d 3e | 0a 4e 65 77 73 67 72 6f |com.com>|.Newsgro|
|00000050| 75 70 73 3a 20 63 6f 6d | 70 2e 6c 61 6e 67 2e 63 |ups: com|p.lang.c|
|00000060| 2b 2b 0a 53 75 62 6a 65 | 63 74 3a 20 52 65 3a 20 |++.Subje|ct: Re: |
|00000070| 55 73 69 6e 67 20 63 69 | 6e 20 6c 69 6b 65 20 73 |Using ci|n like s|
|00000080| 73 63 61 6e 66 28 29 3f | 0a 44 61 74 65 3a 20 35 |scanf()?|.Date: 5|
|00000090| 20 4d 61 72 20 31 39 39 | 36 20 30 35 3a 33 38 3a | Mar 199|6 05:38:|
|000000a0| 33 32 20 47 4d 54 0a 4f | 72 67 61 6e 69 7a 61 74 |32 GMT.O|rganizat|
|000000b0| 69 6f 6e 3a 20 4e 65 74 | 63 6f 6d 0a 4d 65 73 73 |ion: Net|com.Mess|
|000000c0| 61 67 65 2d 49 44 3a 20 | 3c 34 68 67 6b 30 6f 24 |age-ID: |<4hgk0o$|
|000000d0| 70 68 6c 40 63 6c 6f 6e | 65 72 32 2e 69 78 2e 6e |phl@clon|er2.ix.n|
|000000e0| 65 74 63 6f 6d 2e 63 6f | 6d 3e 0a 52 65 66 65 72 |etcom.co|m>.Refer|
|000000f0| 65 6e 63 65 73 3a 20 3c | 34 67 6e 75 64 64 24 64 |ences: <|4gnudd$d|
|00000100| 64 34 40 64 61 69 6c 79 | 2d 70 6c 61 6e 65 74 2e |d4@daily|-planet.|
|00000110| 6e 6f 64 61 6b 2e 65 64 | 75 3e 20 3c 34 68 66 75 |nodak.ed|u> <4hfu|
|00000120| 6d 67 24 6e 70 34 40 6e | 65 77 73 31 2e 69 6e 66 |mg$np4@n|ews1.inf|
|00000130| 69 6e 65 74 2e 63 6f 6d | 3e 0a 4e 4e 54 50 2d 50 |inet.com|>.NNTP-P|
|00000140| 6f 73 74 69 6e 67 2d 48 | 6f 73 74 3a 20 61 75 73 |osting-H|ost: aus|
|00000150| 2d 74 78 35 2d 30 33 2e | 69 78 2e 6e 65 74 63 6f |-tx5-03.|ix.netco|
|00000160| 6d 2e 63 6f 6d 0a 4d 69 | 6d 65 2d 56 65 72 73 69 |m.com.Mi|me-Versi|
|00000170| 6f 6e 3a 20 31 2e 30 0a | 43 6f 6e 74 65 6e 74 2d |on: 1.0.|Content-|
|00000180| 54 79 70 65 3a 20 74 65 | 78 74 2f 70 6c 61 69 6e |Type: te|xt/plain|
|00000190| 3b 20 63 68 61 72 73 65 | 74 3d 75 73 2d 61 73 63 |; charse|t=us-asc|
|000001a0| 69 69 0a 43 6f 6e 74 65 | 6e 74 2d 54 72 61 6e 73 |ii.Conte|nt-Trans|
|000001b0| 66 65 72 2d 45 6e 63 6f | 64 69 6e 67 3a 20 37 62 |fer-Enco|ding: 7b|
|000001c0| 69 74 0a 58 2d 4e 45 54 | 43 4f 4d 2d 44 61 74 65 |it.X-NET|COM-Date|
|000001d0| 3a 20 4d 6f 6e 20 4d 61 | 72 20 30 34 20 20 39 3a |: Mon Ma|r 04 9:|
|000001e0| 33 38 3a 33 32 20 50 4d | 20 50 53 54 20 31 39 39 |38:32 PM| PST 199|
|000001f0| 36 0a 58 2d 4d 61 69 6c | 65 72 3a 20 4d 6f 7a 69 |6.X-Mail|er: Mozi|
|00000200| 6c 6c 61 20 31 2e 32 32 | 20 28 57 69 6e 64 6f 77 |lla 1.22| (Window|
|00000210| 73 3b 20 55 3b 20 31 36 | 62 69 74 29 0a 54 6f 3a |s; U; 16|bit).To:|
|00000220| 20 69 73 68 61 71 40 70 | 6c 61 69 6e 73 2e 6e 6f | ishaq@p|lains.no|
|00000230| 64 61 6b 2e 65 64 75 0a | 0a 0a 4a 65 66 66 72 6f |dak.edu.|..Jeffro|
|00000240| 20 28 69 73 68 61 71 40 | 70 6c 61 69 6e 73 2e 6e | (ishaq@|plains.n|
|00000250| 6f 64 61 6b 2e 65 64 75 | 29 20 77 72 6f 74 65 3a |odak.edu|) wrote:|
|00000260| 0a 3a 20 67 72 65 65 74 | 69 6e 67 73 21 20 20 49 |.: greet|ings! I|
|00000270| 27 76 65 20 61 6c 77 61 | 79 73 20 77 6f 6e 64 65 |'ve alwa|ys wonde|
|00000280| 72 65 64 20 69 66 20 74 | 68 69 73 20 69 73 20 70 |red if t|his is p|
|00000290| 6f 73 73 69 62 6c 65 2e | 20 20 57 65 6c 6c 2c 20 |ossible.| Well, |
|000002a0| 49 27 6d 20 73 75 72 65 | 0a 3a 20 69 74 27 73 20 |I'm sure|.: it's |
|000002b0| 70 6f 73 73 69 62 6c 65 | 2c 20 62 75 74 20 68 6f |possible|, but ho|
|000002c0| 77 20 69 73 20 69 74 20 | 64 6f 6e 65 3f 20 20 53 |w is it |done? S|
|000002d0| 61 79 20 49 20 69 6e 70 | 75 74 20 61 20 73 74 72 |ay I inp|ut a str|
|000002e0| 69 6e 67 20 69 6e 74 6f | 20 73 74 72 69 6e 67 3a |ing into| string:|
|000002f0| 0a 0a 3a 20 63 68 61 72 | 20 73 74 72 69 6e 67 5b |..: char| string[|
|00000300| 5d 20 3d 20 22 54 68 69 | 73 20 69 73 20 61 20 63 |] = "Thi|s is a c|
|00000310| 68 61 72 61 63 74 65 72 | 20 73 74 72 69 6e 67 2e |haracter| string.|
|00000320| 22 3b 0a 3a 20 63 68 61 | 72 20 62 75 66 66 65 72 |";.: cha|r buffer|
|00000330| 5b 32 34 5d 3b 0a 0a 3a | 20 48 6f 77 20 63 61 6e |[24];..:| How can|
|00000340| 20 49 20 74 65 6c 6c 20 | 63 69 6e 20 74 6f 20 72 | I tell |cin to r|
|00000350| 65 61 64 20 66 72 6f 6d | 20 73 74 72 69 6e 67 20 |ead from| string |
|00000360| 69 6e 73 74 65 61 64 20 | 6f 66 20 73 74 64 69 6e |instead |of stdin|
|00000370| 20 73 6f 20 49 20 63 61 | 6e 20 64 6f 0a 3a 20 73 | so I ca|n do.: s|
|00000380| 6f 65 6d 74 68 69 6e 67 | 20 6c 69 6b 65 20 74 68 |oemthing| like th|
|00000390| 69 73 3a 0a 0a 3a 20 2f | 2f 63 69 6e 2e 72 65 61 |is:..: /|/cin.rea|
|000003a0| 64 5f 66 72 6f 6d 28 73 | 74 72 69 6e 67 29 0a 3a |d_from(s|tring).:|
|000003b0| 20 77 68 69 6c 65 20 28 | 63 69 6e 20 3e 3e 20 62 | while (|cin >> b|
|000003c0| 75 66 66 65 72 29 20 63 | 6f 75 74 20 3c 3c 20 62 |uffer) c|out << b|
|000003d0| 75 66 66 65 72 3b 20 20 | 20 20 2f 2f 4f 75 74 70 |uffer; | //Outp|
|000003e0| 75 74 73 20 73 74 72 69 | 6e 67 0a 3a 20 2f 2f 63 |uts stri|ng.: //c|
|000003f0| 69 6e 2e 72 65 61 64 5f | 66 72 6f 6d 28 73 74 64 |in.read_|from(std|
|00000400| 69 6e 29 0a 0a 3a 20 54 | 68 69 73 20 73 68 6f 75 |in)..: T|his shou|
|00000410| 6c 64 20 62 65 20 73 69 | 6d 69 6c 61 72 20 74 6f |ld be si|milar to|
|00000420| 3a 0a 0a 3a 20 77 68 69 | 6c 65 20 28 73 73 63 61 |:..: whi|le (ssca|
|00000430| 6e 66 28 73 74 72 69 6e | 67 2c 20 22 25 73 22 2c |nf(strin|g, "%s",|
|00000440| 20 26 62 75 66 66 65 72 | 29 29 20 63 6f 75 74 20 | &buffer|)) cout |
|00000450| 3c 3c 20 62 75 66 66 65 | 72 3b 0a 0a 3a 20 41 6e |<< buffe|r;..: An|
|00000460| 79 20 69 64 65 61 73 3f | 0a 3a 20 54 68 61 6e 6b |y ideas?|.: Thank|
|00000470| 73 21 0a 3a 20 09 2d 6a | 65 66 66 0a 0a 20 20 20 |s!.: .-j|eff.. |
|00000480| 20 20 20 52 65 6d 65 6d | 62 65 72 2c 20 77 65 20 | Remem|ber, we |
|00000490| 61 72 65 20 69 6e 20 4f | 4f 50 2d 6c 61 6e 64 20 |are in O|OP-land |
|000004a0| 6e 6f 77 2e 20 20 27 43 | 69 6e 27 20 69 73 20 6e |now. 'C|in' is n|
|000004b0| 6f 74 20 61 20 66 75 6e | 63 74 69 6f 6e 20 6c 69 |ot a fun|ction li|
|000004c0| 6b 65 20 74 68 65 20 0a | 76 61 72 69 6f 75 73 20 |ke the .|various |
|000004d0| 70 65 72 6d 75 74 61 74 | 69 6f 6e 73 20 6f 66 20 |permutat|ions of |
|000004e0| 73 63 61 6e 2e 20 20 43 | 69 6e 20 69 73 20 61 6e |scan. C|in is an|
|000004f0| 20 73 74 72 65 61 6d 20 | 6f 62 6a 65 63 74 2e 20 | stream |object. |
|00000500| 20 54 68 65 20 66 75 6e | 63 74 69 6f 6e 73 20 6f | The fun|ctions o|
|00000510| 72 0a 6d 65 74 68 6f 64 | 73 20 6f 66 20 43 69 6e |r.method|s of Cin|
|00000520| 20 61 72 65 20 43 69 6e | 2e 67 65 74 28 29 2c 20 | are Cin|.get(), |
|00000530| 74 68 65 20 3c 3c 20 6f | 70 65 72 61 74 6f 72 2c |the << o|perator,|
|00000540| 20 65 74 63 2e 20 20 54 | 68 65 20 73 74 61 6e 64 | etc. T|he stand|
|00000550| 61 72 64 20 69 6e 70 75 | 74 2c 20 0a 73 74 64 69 |ard inpu|t, .stdi|
|00000560| 6e 2c 20 69 73 20 6c 69 | 6b 65 20 74 68 65 20 64 |n, is li|ke the d|
|00000570| 61 74 61 20 6d 65 6d 62 | 65 72 20 6f 66 20 43 69 |ata memb|er of Ci|
|00000580| 6e 2c 20 61 6e 64 20 69 | 74 20 69 73 20 68 69 64 |n, and i|t is hid|
|00000590| 64 65 6e 2c 20 79 6f 75 | 20 63 61 6e 20 6f 6e 6c |den, you| can onl|
|000005a0| 79 20 67 65 74 20 0a 61 | 74 20 77 68 61 74 20 69 |y get .a|t what i|
|000005b0| 73 20 27 69 6e 27 20 73 | 74 64 69 6e 20 62 79 20 |s 'in' s|tdin by |
|000005c0| 6d 61 6b 69 6e 67 20 75 | 73 65 20 6f 66 20 74 68 |making u|se of th|
|000005d0| 65 20 6d 65 6d 62 65 72 | 20 61 6e 64 20 66 72 69 |e member| and fri|
|000005e0| 65 6e 64 20 66 75 6e 63 | 74 69 6f 6e 73 20 6f 66 |end func|tions of|
|000005f0| 20 0a 43 69 6e 2e 20 20 | 54 68 65 20 6f 6e 6c 79 | .Cin. |The only|
|00000600| 20 77 61 79 20 79 6f 75 | 20 63 6f 75 6c 64 20 6d | way you| could m|
|00000610| 61 6b 65 20 74 68 65 20 | 6d 65 6d 62 65 72 20 66 |ake the |member f|
|00000620| 75 6e 63 74 69 6f 6e 73 | 20 6f 66 20 43 69 6e 20 |unctions| of Cin |
|00000630| 77 6f 72 6b 20 6f 6e 0a | 73 6f 6d 65 74 68 69 6e |work on.|somethin|
|00000640| 67 20 6f 74 68 65 72 20 | 74 68 61 6e 20 73 74 64 |g other |than std|
|00000650| 69 6e 20 77 6f 75 6c 64 | 20 62 65 20 74 6f 20 72 |in would| be to r|
|00000660| 65 64 65 66 69 6e 65 20 | 74 68 65 20 65 6e 74 69 |edefine |the enti|
|00000670| 72 65 20 63 6c 61 73 73 | 20 6f 66 0a 77 68 69 63 |re class| of.whic|
|00000680| 68 20 43 69 6e 20 69 73 | 20 61 6e 20 69 6e 73 74 |h Cin is| an inst|
|00000690| 61 6e 63 65 2c 20 73 75 | 63 68 20 74 68 61 74 20 |ance, su|ch that |
|000006a0| 74 68 65 20 68 69 64 64 | 65 6e 20 64 61 74 61 20 |the hidd|en data |
|000006b0| 6d 65 6d 62 65 72 20 77 | 68 69 63 68 20 74 68 65 |member w|hich the|
|000006c0| 0a 6d 65 6d 62 65 72 20 | 66 75 6e 63 74 69 6f 6e |.member |function|
|000006d0| 73 20 6f 66 20 43 69 6e | 20 61 63 74 20 6f 6e 20 |s of Cin| act on |
|000006e0| 77 61 73 20 73 6f 6d 65 | 74 68 69 6e 67 20 65 6c |was some|thing el|
|000006f0| 73 65 2c 20 61 6e 64 20 | 74 68 61 74 20 77 6f 75 |se, and |that wou|
|00000700| 6c 64 20 62 65 0a 61 20 | 63 6f 75 6e 74 65 72 70 |ld be.a |counterp|
|00000710| 72 6f 64 75 63 74 69 76 | 65 20 74 68 69 6e 67 20 |roductiv|e thing |
|00000720| 74 6f 20 64 6f 2e 0a 20 | 20 20 20 20 20 59 6f 75 |to do.. | You|
|00000730| 20 63 6f 75 6c 64 20 64 | 65 66 69 6e 65 20 79 6f | could d|efine yo|
|00000740| 75 72 20 6f 77 6e 20 63 | 6c 61 73 73 20 77 68 69 |ur own c|lass whi|
|00000750| 63 68 20 61 6c 6c 6f 77 | 65 64 20 79 6f 75 20 74 |ch allow|ed you t|
|00000760| 6f 20 6d 61 6b 65 20 75 | 73 65 0a 6f 66 20 74 68 |o make u|se.of th|
|00000770| 65 20 3e 3e 20 61 6e 64 | 20 3c 3c 20 6f 70 65 72 |e >> and| << oper|
|00000780| 61 74 6f 72 73 20 69 6e | 20 74 68 65 20 73 61 6d |ators in| the sam|
|00000790| 65 20 77 61 79 20 79 6f | 75 20 64 6f 20 77 69 74 |e way yo|u do wit|
|000007a0| 68 20 63 69 6e 20 61 6e | 64 20 63 6f 75 74 2c 20 |h cin an|d cout, |
|000007b0| 0a 62 75 74 20 74 68 69 | 73 20 68 61 73 20 61 6c |.but thi|s has al|
|000007c0| 72 65 61 64 79 20 62 65 | 65 6e 20 64 6f 6e 65 20 |ready be|en done |
|000007d0| 66 6f 72 20 79 6f 75 2e | 20 20 43 68 65 63 6b 20 |for you.| Check |
|000007e0| 6f 75 74 20 74 68 65 20 | 63 6c 61 73 73 65 73 20 |out the |classes |
|000007f0| 0a 69 73 74 72 73 74 72 | 65 61 6d 2c 20 6f 73 74 |.istrstr|eam, ost|
|00000800| 72 73 74 72 65 61 6d 2c | 20 61 6e 64 20 73 74 72 |rstream,| and str|
|00000810| 73 74 72 65 61 6d 2e 20 | 20 49 20 74 68 69 6e 6b |stream. | I think|
|00000820| 20 44 61 76 69 64 20 42 | 79 72 6e 65 20 68 61 64 | David B|yrne had|
|00000830| 0a 74 68 65 20 72 69 67 | 68 74 20 69 64 65 61 2e |.the rig|ht idea.|
|00000840| 20 20 0a 0a 20 20 20 20 | 20 20 20 20 20 20 20 20 | .. | |
|00000850| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00000860| 20 20 20 20 20 20 20 20 | 20 20 20 20 20 20 20 20 | | |
|00000870| 20 20 20 20 20 20 20 20 | 20 20 20 2d 5a 20 20 0a | | -Z .|
|00000880| 20 20 0a 0a 0a | | ... | |
+--------+-------------------------+-------------------------+--------+--------+